-
Notifications
You must be signed in to change notification settings - Fork 66
✨ Implement Boxcutter #1946
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
✨ Implement Boxcutter #1946
Conversation
❌ Deploy Preview for olmv1 failed.
|
hasher.Reset() | ||
|
||
printer := spew.ConfigState{ | ||
Indent: " ", | ||
SortKeys: true, | ||
DisableMethods: true, | ||
SpewKeys: true, | ||
} | ||
if _, err := printer.Fprintf(hasher, "%#v", objectToWrite); err != nil { | ||
panic(err) | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this an OLM-ism or a boxcutter-ism? I wonder if json.NewEncoder(hasher).Encode(objectToWrite)
would be better?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is a kubernetes apimachinery thing:
https://github.com/kubernetes/kubernetes/blob/627ce4946ccd6b67bc18f5a4dda92cf6c583e9b7/pkg/util/hash/hash.go#L26-L32
https://github.com/kubernetes/apimachinery/blob/master/pkg/util/dump/dump.go
I'll import from apimachinery next.
36d9cd7
to
b401796
Compare
1c23866
to
dc66501
Compare
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #1946 +/- ##
==========================================
- Coverage 72.61% 69.85% -2.77%
==========================================
Files 78 83 +5
Lines 7260 7965 +705
==========================================
+ Hits 5272 5564 +292
- Misses 1633 2015 +382
- Partials 355 386 +31
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
35cdf3b
to
370bac6
Compare
4f39c38
to
842037e
Compare
b3f1de0
to
6827d71
Compare
# DO NOT ADD A NAMESPACE HERE | ||
--- | ||
apiVersion: kustomize.config.k8s.io/v1alpha1 | ||
kind: Component |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This component is not used... it's not being included in the experimental manifests (yet).
See:
https://github.com/operator-framework/operator-controller/blob/main/config/components/base/experimental/kustomization.yaml
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That was intentional. Boxcutter runtime is orthogonal to all other feature gates. I think, at least for the time being, it is preferable to e2e tests the other FGs against the standard applier.
BundlePathCSV = BundlePathManifests + "/csv.yaml" | ||
) | ||
|
||
func NewBundleFS() fstest.MapFS { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What's the benefit to moving this out of the bundle/source/source_test.go? I'm not seeing it used anywhere else. It just feels as though it's making the PR bigger without benefit?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's used in the boxcutter applier test [e.g.]
sch := apimachineryruntime.NewScheme() | ||
require.NoError(t, ocv1.AddToScheme(sch)) | ||
cl, err := client.New(config, client.Options{Scheme: sch}) | ||
cl, err := client.New(config, client.Options{Scheme: newScheme(t)}) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Again, not seeing the benefit of putting this into a function.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
used by the controllerextensionrevision_controller test, [e.g.]
go.mod
Outdated
replace pkg.package-operator.run/boxcutter => github.com/perdasilva/boxcutter v0.0.0-20250715101157-18ea858f54bd | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Presumably, temporary, until you get your boxcutter changes merged?
6827d71
to
6cd5b57
Compare
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: The full list of commands accepted by this bot can be found here.
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
…time libs Signed-off-by: Per Goncalves da Silva <pegoncal@redhat.com>
Signed-off-by: Per Goncalves da Silva <pegoncal@redhat.com>
Signed-off-by: Per Goncalves da Silva <pegoncal@redhat.com>
Signed-off-by: Per Goncalves da Silva <pegoncal@redhat.com>
Signed-off-by: Per Goncalves da Silva <pegoncal@redhat.com>
Signed-off-by: Per Goncalves da Silva <pegoncal@redhat.com>
Signed-off-by: Per Goncalves da Silva <pegoncal@redhat.com>
Signed-off-by: Per Goncalves da Silva <pegoncal@redhat.com>
Signed-off-by: Per Goncalves da Silva <pegoncal@redhat.com>
Signed-off-by: Per Goncalves da Silva <pegoncal@redhat.com>
Signed-off-by: Per Goncalves da Silva <pegoncal@redhat.com>
Signed-off-by: Joe Lanford <joe.lanford@gmail.com>
Signed-off-by: Joe Lanford <joe.lanford@gmail.com>
…re component Signed-off-by: Joe Lanford <joe.lanford@gmail.com>
d96b88a
to
294dd8c
Compare
Signed-off-by: Todd Short <tshort@redhat.com>
Signed-off-by: Todd Short <tshort@redhat.com>
Description
Reviewer Checklist